import request from '@/utils/request';


//新增事务
export const reTaskadd = (data:any) =>request.put<any,any>("/tasks/add",data)
//编辑事务
export const reTaskupdate = (data:any) =>request.put<any,any>("/tasks/update",data)
//删除
export const reTaskdelete = (id:number) =>request.delete<any,any>(`/tasks/delete?id=${id}`)

//获取事务列表
export const regetTaskList = () =>request.get<any,any>("/tasks/list")

//更新状态
export const reTaskupdateStatus = (id:any ,staus:any) =>request.post<any,any>(`/tasks/updateStatus?id=${id}&status=${staus}`)

export const reTasknow = (id:any) =>request.get<any,any>(`/tasks/?id=${id}`)

//今日事务
export const regetTaskListToday = () =>request.get<any,any>(`/tasks/today`)